<template>
    <el-card style="width: 100%">
    <template #header>
      <div class="card-header">
        <!--库存量统计 -->
        <el-row>
            <el-col :sm="12" :lg="8">
            <el-result
                icon="success"
                title="录入总数"
                sub-title="10">
            </el-result>
            </el-col>
            <el-col :sm="12" :lg="8">
            <el-result
                icon="success"
                title="已核对"
                sub-title="4">
            </el-result>
            </el-col>
            <el-col :sm="12" :lg="8">
            <el-result
                icon="success"
                title="未核对"
                sub-title="6">
            </el-result>
            </el-col>
        </el-row>
        <!-- 按钮 -->
        <div>
            <el-button type="primary">添加</el-button>
            <el-button type="danger">批量删除</el-button>
        </div>
      </div>
    </template>
    <el-table :data="tableData" style="width: 100%">
      <el-table-column prop="date" label="日期"></el-table-column>
      <el-table-column prop="name" label="姓名"></el-table-column>
      <el-table-column prop="address" label="地址"></el-table-column>
      <!-- 操作 -->
      <el-table-column label="操作">
      <template #default="scope">
        <el-button size="small" @click="handleEdit(scope.$index, scope.row)">
          编辑
        </el-button>
        <el-button
          size="small"
          type="danger"
          @click="handleDelete(scope.$index, scope.row)"
        >
          删除
        </el-button>
      </template>
    </el-table-column>
    </el-table>
    <template #footer>Footer content</template>
    </el-card>
  </template>

<script lang="ts" setup>
const tableData = [
  {
    date: '2016-05-03',
    name: 'Tom',
    address: 'No. 189, Grove St, Los Angeles',
  },
  {
    date: '2016-05-02',
    name: 'Tom',
    address: 'No. 189, Grove St, Los Angeles',
  },
  {
    date: '2016-05-04',
    name: 'Tom',
    address: 'No. 189, Grove St, Los Angeles',
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: 'No. 189, Grove St, Los Angeles',
  },
]
</script>